home *** CD-ROM | disk | FTP | other *** search
/ Aminet 1 (Walnut Creek) / Aminet - June 1993 [Walnut Creek].iso / aminet / misc / sci / ephem_bin_4_28.lha / Readme < prev   
Text File  |  1992-04-17  |  5KB  |  125 lines

  1. General Notes for ephem:
  2.  
  3. 1) Start by reading the generic-printer-ready manual in Man.txt.
  4.  
  5. If you have source, here is how you build ephem:
  6.  
  7. 1) io.c:
  8.    define UNIX, VMS or TURBO_C in io.c depending on your system. Note that
  9.    TURBO_C also seems to work ok with Microsoft and Lattice C too but these
  10.    have not been tested recently. Note also that the VMS C compiler defines VMS
  11.    automatically so you don't really have to #define it.
  12.  
  13.    Also in io.c and if you use UNIX, you have four choices of methods for doing
  14.    non-blocking reads and two choices for controlling tty modes. #define one
  15.    of USE_FIONREAD, USE_NDELAY, USE_ATTSELECT and USE_BSDSELECT and one of
  16.    USE_TERMIO and USE_SGTTY.
  17.  
  18.    And also in io.c MSDOS users may do cursor control with direct BIOS calls
  19.    (the default), or with ANSI.SYS by defining USE_ANSISYS.
  20.  
  21. 2) time.c:
  22.    Select from two methods of dealing with time from the operating system
  23.    with the TZA/TZB defines in time.c. If you get link undefines related to
  24.    time functions try changing to the other form.
  25.  
  26.    On Sun systems running OS 4.0.3 (or BSD 4.3) or Apollo SR 10.1 use TZB and
  27.    change <time.h> to <sys/time.h>.
  28.  
  29.    For VMS, since it does not support time zone info, do NOT #define EITHER
  30.    of TZA or TZB. This will have the effect of leaving the time zone unchanged
  31.    whenever you set the time via the "Now" option. (This is taken care of
  32.    automatically in time.c by #undef'ining TZA and TZB if VMS is defined.)
  33.  
  34. 3) mainmenu.c:
  35.    if you are compiling for an IBM-PC then #define PC_GRAPHICS for a nicer
  36.    looking way to draw the screen boundry lines using character graphics.
  37.  
  38. 4) sel_fld.c:
  39.    if your runtime library supports the system() function (to run a shell
  40.    command) then leave #define BANG in sel_fld.c, else undefine it. When
  41.    defined, this will allow you to jump out of ephem and run any command,
  42.    then resume where you left off.
  43.  
  44. 5) beware that I have not used string.h or strings.h. if your library's
  45.    strlen() and str.*cmp() functions don't return int (such as long), then you
  46.    will have to hand add string.h or your own extern declarations. I have
  47.    included all the necessary declarations for the functions that return
  48.    (char *) such as strcpy(), etc, though.
  49.  
  50. 6) main.c calls sleep() which is not in some IBM-PC runtime C libraries. You
  51.    might kludge up your own call that does a cpu countdown loop. The accuracy
  52.    will only effect the Pause feature, not ephem's actual time mechanisms.
  53.  
  54. 7) Ephem can now be built by simply compiling all the .c files and linking them
  55.    all together. On Unix systems, you must also link with the termcap library
  56.    (-ltermcap) and possibly the auxiliary math library (-lm) if your default C
  57.    library does not include all the required transcendental functions. At the
  58.    end of this file I have included a VMS build script for those building
  59.    ephem on a that system.
  60.  
  61. The following files are pretty much just pure transliterations from BASIC
  62. into C from machine-readable copies of the programs in Duffett-Smith's book.
  63. They have nothing to do with the rest of ephem so they may be used for
  64. completely different applications if so desired.
  65.  
  66.    aa_hadec.c anomaly.c astro.h cal_mjd.c comet.c eq_ecl.c moon.c moonnf.c
  67.    nutation.c obliq.c parallax.c pelement.c plans.c reduce.c refract.c
  68.    sex_dec.c sun.c utc_gst.c
  69.  
  70. If you would like to gut ephem for just its astronomical functionality,
  71. start with body_cir().
  72.  
  73. $!========================================================================
  74. $!
  75. $! Name      : BUILD.COM
  76. $!
  77. $! Purpose   : compile and link ephem under VMS
  78. $!
  79. $! Arguments : P1/P2 = DEBUG: compile with DEBUG info
  80. $!             P1/P2 = LINK : link only
  81. $!             P1    = nn   : start compiling at list element "nn" (0-36)
  82. $!
  83. $! Created  23-MAR-1990   Karsten Spang
  84. $! Modified 31-AUG-1990   Rick Dyson
  85. $!                        added listing to FILES for v4.19
  86. $!                        added P1 = nn option
  87. $!
  88. $!========================================================================
  89. $   VERIFY = F$Verify (0)
  90. $   On ERROR     Then GoTo EXIT
  91. $   On CONTROL_Y Then GoTo EXIT
  92. $   If P1 .eqs. "DEBUG" .or. P2 .eqs. "DEBUG"
  93. $       Then
  94. $           CC      := Cc /Debug /NoOptimize /NoList
  95. $           LINK    := Link /Debug /NoMap
  96. $       Else
  97. $           CC      := Cc /NoList
  98. $           LINK    := Link /NoMap
  99. $   EndIf
  100. $   FILES = "MAIN,AA_HADEC,ALTJ,ALTMENUS,ANOMALY,CAL_MJD,CIRCUM,COMET,"+ -
  101.         "COMPILER,CONSTEL,EQ_ECL,FLOG,FORMATS,IO,LISTING,MAINMENU,"+ -
  102.     "MOON,MOONNF,NUTATION,OBJX,OBLIQ,PARALLAX,PELEMENT,PLANS,PLOT,"+ -
  103.         "POPUP,PRECESS,REDUCE,REFRACT,RISET,RISET_C,SEL_FLD,SEX_DEC,SRCH,"+ -
  104.         "SUN,TIME,UTC_GST,VERSION,WATCH"
  105. $   If P1 .eqs. "LINK" .or. P2 .eqs. "LINK" Then GoTo LINK
  106. $   FILE_NUM = F$Integer (P1)
  107. $   If (FILE_NUM .ge. 37 .or. FILE_NUM .lt. 0) Then FILE_NUM = 0
  108. $COMPILE_LOOP:
  109. $   FILE = F$Element (FILE_NUM, "," ,FILES)
  110. $   If FILE .eqs. "," Then GoTo COMPILE_END
  111. $   Write Sys$Output "Compiling file number ''FILE_NUM' = ''FILE' ..."
  112. $   CC 'FILE'
  113. $   FILE_NUM = FILE_NUM + 1
  114. $   GoTo COMPILE_LOOP
  115. $COMPILE_END:
  116. $LINK:
  117. $   Write Sys$Output "Linking ephem now...^G"
  118. $   LINK /Exe = EPHEM 'FILES',Sys$Input/Opt
  119. Sys$Library:VAXCRTL/Share
  120. $EXIT:
  121. $   Set NoOn
  122. $   Purge *.OBJ,*.EXE
  123. $   If VERIFY Then Set Verify
  124. $   Exit
  125.